Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply masks & clean pixel to any type of non compliant image #231

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mhenx
Copy link
Collaborator

@mhenx mhenx commented Feb 25, 2025

Some XA or RF images (or any kind) can contain patient information in the image depending on the station that produced the image
Clean pixel profile element application conditions
This profile is applied only on the following SOP:

1.2.840.10008.5.1.4.1.1.6.1 - Ultrasound Image Storage
1.2.840.10008.5.1.4.1.1.7.1 - Multiframe Single Bit Secondary Capture Image Storage
1.2.840.10008.5.1.4.1.1.7.2 - Multiframe Grayscale Byte Secondary Capture Image Storage
1.2.840.10008.5.1.4.1.1.7.3 - Multiframe Grayscale Word Secondary Capture Image Storage
1.2.840.10008.5.1.4.1.1.7.4 - Multiframe True Color Secondary Capture Image Storage
1.2.840.10008.5.1.4.1.1.3.1 - Ultrasound Multiframe Image Storage
1.2.840.10008.5.1.4.1.1.77.1.1 - VL endoscopic Image Storage
Or if the tag value Burned In Annotation (0028,0301) is “YES”

For the images outside this scope, a mask cannot be applied

Following the implementation of the new feature #228 we can now define a profile that adds the BurnedInAnnotation attributes and sets its value properly

Example of profile:

name: "Clean pixel data"
version: "1.0"
minimumKarnakVersion: "0.9.2"
defaultIssuerOfPatientID:
profileElements:

  • name: "Add tag BurnedInAnnotation if does not exist"
    codename: "action.add.tag"
    condition: "tagValueContains(#Tag.StationName, 'ICT256') && !tagIsPresent(#Tag.BurnedInAnnotation)"
    arguments:
    value: "YES"
    vr: "CS"
    tags:

    • "(0028,0301)"
  • name: "Set BurnedInAnnotation to YES"
    codename: "expression.on.tags"
    condition: "tagValueContains(#Tag.StationName, 'ICT256')"
    arguments:
    expr: "Replace('YES')"
    tags:

    • "(0028,0301)"
  • name: "Clean pixel data"
    codename: "clean.pixel.data"

  • name: "DICOM basic profile"
    codename: "basic.dicom.profile"

masks:

  • ...

@mhenx mhenx linked an issue Feb 25, 2025 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Clean pixel data limitation
1 participant